﻿using System.Linq;

namespace CoreLims.Models.CoreLims
{
    using SampleBatch = SampleSampleBatch;

    public static class SampleSampleBatchExtension
    {
        /// <summary>
        /// 根据 ID 获取样品单
        /// </summary>
        /// <param name="sample"></param>
        /// <param name="dbContext"></param>
        /// <param name="Id"></param>
        /// <returns></returns>
        public static SampleBatch getSampleBatch(this SampleBatch sample, CoreLimsContext dbContext, string Id) =>
            dbContext.SampleSampleBatch.FirstOrDefault(s => s.Id == Id);


    }

}
